<div class="row">
    <div class="col-md-12">
        <div class="card dcat-box">
            <div class="box-header with-border">
                <h3 class="box-title" style="line-height:30px;">
                    提交内容
                </h3>
                <div class="pull-right">
                    <div class="btn-group pull-right btn-mini" style="margin-right: 5px">
                        <a href="{{ admin_route('diy_form_content.index') }}" class="btn btn-sm btn-primary ">
                            <i class="feather icon-list"></i><span class="d-none d-sm-inline"> 列表</span>
                        </a>
                    </div>
                </div>
            </div>
            <div class="box-body">
                <div class="form-horizontal mt-1">
                    @foreach($info->content as $item)
                        <div class="show-field form-group row">
                            <div class="col-sm-2 control-label">
                                <span>{{ $item['label'] }}</span>
                            </div>
                            <div class="col-sm-8">
                                <div class="box box-solid box-default no-margin box-show">
                                    <div class="box-body">
                                        @if(in_array($item['type'], ['select', 'radio', 'checkbox']))
                                            @php $data = collect($item['options'])->whereIn('key', explode(',', $item['data']))->pluck('value')->all(); @endphp
                                            {{ implode(',', $data) }}
                                        @elseif($item['type'] == 'img')
                                            @foreach(explode(',', $item['data']) as $img)
                                                <img data-action="preview-img" src="{{ $img }}" style="max-width:200px;max-height:200px" class="img">  &nbsp;
                                            @endforeach
                                        @else
                                            {{ $item['data'] ?? '' }}
                                        @endif
                                    </div>
                                </div>
                            </div>
                        </div>
                    @endforeach
                </div>
            </div>
        </div>
    </div>
</div>
